<?php
$form = $this->beginWidget('bootstrap.widgets.TbActiveForm', array(
    'id' => 'category-form',
    'enableAjaxValidation' => false,
    'enableClientValidation' => true,
    'type' => 'horizontal',
    'htmlOptions' => array(
	'enctype' => 'multipart/form-data'
    )
	));
?>

<p class="help-block">Fields with <span class="required">*</span> are required.</p>

<?php echo $form->errorSummary($model); ?>

<?php echo $form->textFieldRow($model, 'name', array('class' => 'span5', 'maxlength' => 255)); ?>

<?php echo $form->textFieldRow($model, 'alias', array('class' => 'span5', 'maxlength' => 255)); ?>

<?php echo $form->textFieldRow($model, 'price_two_week', array('class' => 'span5')); ?>
<?php echo $form->textFieldRow($model, 'price_one_month', array('class' => 'span5')); ?>
<?php echo $form->textFieldRow($model, 'price_3_month', array('class' => 'span5')); ?>
<?php echo $form->textFieldRow($model, 'price_6_month', array('class' => 'span5')); ?>
<?php echo $form->textFieldRow($model, 'price_one_year', array('class' => 'span5')); ?>
<?php echo $form->textFieldRow($model, 'price_addition', array('class' => 'span5')); ?>
<?php echo $form->textFieldRow($model, 'price_e_blast', array('class' => 'span5')); ?>


<?php if (!$model->isNewRecord) : ?>
    <div class="control-group">
        <label class="control-label">Current Icon</label>
        <div class="controls">
    	<img src="<?php echo $model->getIconUrl() ?>" />
        </div>
    </div>
<?php endif; ?>

<?php echo $form->hiddenField($model, 'icon', array('class' => 'span5', 'maxlength' => 255)); ?>
<div class="control-group">
    <label class="control-label">Select Icon</label>
    <div class="controls">
	<?php echo CHtml::fileField('icon') ?>
    </div>
</div>

<?php echo $form->textFieldRow($model, 'meta_keywords', array('class' => 'span5', 'maxlength' => 255)); ?>

<?php echo $form->textAreaRow($model, 'meta_description', array('class' => 'span5', 'maxlength' => 255)); ?>

<?php echo $form->textFieldRow($model, 'meta_title', array('class' => 'span5', 'maxlength' => 255)); ?>

<div class="form-actions">
    <?php
    $this->widget('bootstrap.widgets.TbButton', array(
	'buttonType' => 'submit',
	'type' => 'primary',
	'label' => $model->isNewRecord ? 'Create' : 'Save',
    ));
    ?>
</div>

<?php $this->endWidget(); ?>
